import { defineComponent } from "vue";
import styles from "./Operation.module.less";

export default defineComponent({
  props: {
    btns: {
      type: Array,
    }
  },
  setup(props) {
    return () => (
      <div class={styles.operation}>
        {
          props.btns?.map((item: any, index: number) => (
            <>
              {item?.()}
              {
                (props.btns && index < props.btns?.length - 1) && <a-divider type="vertical" />
              }
            </>
          ))
        }
      </div>
    )
  }
})